package com.bidevalution.business.enums;

/**
 * 表决发起类型
 */
public enum VoteTypeEnum {
    Manual(1,"手动发起"),
    Automatic(0,"自动发起");

    public int code;
    public String name;

    VoteTypeEnum(int code, String name){
        this.code = code;
        this.name = name;
    }

    public static VoteTypeEnum getVoteTypeEnum(int code) {
        for(VoteTypeEnum item : VoteTypeEnum.values()) {
            if (item.code == code) {
                return item;
            }
        }
        return null;
    }

    public int getCode() {
        return code;
    }

    public String getName() {
        return name;
    }
}
